let makeclass = require("./modules/make_class.js");

let moban1 = {
    name:"模板1",
    extend:null,
    mv1:"member vaule1",
    ctor:function(){
        this.mv1 += " ctor";
    },
    mfunc1:function(){
        console.log(this.mv1);
    },
    static:{
        sv1:"static vaule1",
        sa1:[1,2],
        sfunc1:function(){
            console.log(this.sv1);
        }
    }
};

let moban2 = {
    name:"模板2",
    extend:moban1,
    mv2:"member vaule2",
    ctor:function(){
        this.mv1 += " 2";
    },
    mfunc2:function(){
        console.log(this.mv2);
    },
    static:{
        sv2:"static vaule2",
        sfunc2:function(){
            console.log(this.sv2);
        }
    }
};

let moban3 = {
    name:"模板3",
    extend:moban2,
    mv3:"member vaule3",
    mfunc3:function(){
        console.log(this.mv3);
    }
};

let c1 = new makeclass(moban3);
let c2 = new makeclass(moban2);
let c3 = new makeclass(moban3);
c1.mfunc1();
c1.static.sfunc1();
c1.mfunc2();
c1.static.sfunc2();
c1.mfunc3();
c1.static.sv1 = "555";
c1.static.sa1.push(9);

c2.mfunc1();
c2.static.sfunc1();
c2.static.sv2 = "666";
c2.static.sv1 = "777";

c3.static.sfunc1();
c3.static.sfunc2();